package com.iSnail.ms.gather.ui;

import java.awt.Component;

import javax.swing.ImageIcon;
import javax.swing.JTree;
import javax.swing.tree.DefaultTreeCellRenderer;

public class RootNode extends DefaultTreeCellRenderer {
	ImageIcon rootIcon;

	public RootNode() {
		rootIcon = new ImageIcon("resource/pic/root.png");
	}

	public Component getTreeCellRendererComponent(JTree tree, Object value, boolean sel, boolean expanded, boolean leaf, int row, boolean hasFocus) {
		setIcon(rootIcon);
		return this;
	}
}